Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Miguelcds/App_AsignadorZonasBilbao/llms.txt

Use this file to discover all available pages before exploring further.

This page describes every data format the app reads, writes, or stores.

Input Excel file

The app accepts .xlsx and .xls files. The file must contain a column named exactly Calle.
RequirementDetail
Column nameCalle (case-sensitive)
Supported formats.xlsx, .xls
Column positionAny column in the sheet
Other columnsPreserved unchanged in the output
Example input:
CalleCódigo PostalMunicipio
Gran Vía Don Diego López de Haro48001Bilbao
Calle Iparraguirre48011Bilbao
Calle Blas de Otero48014Bilbao
If the Calle column is missing, the app cannot assign zones and will report all rows as unmatched.

Output Excel file

The app writes a new file named Calles_Asignadas.xlsx. It contains all original columns plus a Zona column appended at the end.
PropertyValue
File nameCalles_Asignadas.xlsx
Sheet nameCalles con Zonas
New columnZona
Unmatched rowsZona cell left empty
Example output:
CalleCódigo PostalMunicipioZona
Gran Vía Don Diego López de Haro48001BilbaoBilbao Centro
Calle Iparraguirre48011BilbaoBilbao Centro
Calle Blas de Otero48014BilbaoDeusto
The app uses the following SheetJS calls to produce this file:
const ws = XLSX.utils.json_to_sheet(processedData);
const wb = XLSX.utils.book_new();
XLSX.utils.book_append_sheet(wb, ws, 'Calles con Zonas');
XLSX.writeFile(wb, 'Calles_Asignadas.xlsx');

Dictionary format (js/data.js)

The standard dictionary is a plain JavaScript object named zonasEstandar. Each key is an uppercase string fragment that is matched as a substring against street values. Each value is the zone name string to assign.
const zonasEstandar = {
    // DEUSTO
    "ANDALUCÍA":             "Deusto",
    "ARAGÓN":                "Deusto",
    "AV MADARIAGA":          "Deusto",
    "AV RAMON Y CAJAL":      "Deusto",
    "BLAS DE OTERO":         "Deusto",
    "BURGOS":                "Deusto",
    "CANTABRIA":             "Deusto",
    "GALICIA":               "Deusto",
    "GREGORIO BALPARDA":     "Deusto",
    "ITURRIKOETXE":          "Deusto",

    // DEUSTO MUELLE
    "RI DEUSTU":             "Deusto Muelle",
    "RAMAL OLABEAGA":        "Deusto Muelle",
    "RI ZORROTZAURRE":       "Deusto Muelle",
    "CARGUERAS":             "Deusto Muelle",
    "SAGARDUI":              "Deusto Muelle",

    // DEUSTO MONTE
    "GORBEIA":               "Deusto Monte",
    "MONTE JATA":            "Deusto Monte",

    // BILBAO CENTRO
    "IPARRAGUIRRE":          "Bilbao Centro",
    "AUTONOMIA":             "Bilbao Centro",
    "GENERAL EGUIA":         "Bilbao Centro",

    // ... (additional entries)
};
Key rules:
  • Keys must be uppercase. The matching algorithm uppercases the input before comparison, so mixed-case keys will not match.
  • Keys are matched as substrings, not exact matches.
  • Shorter or more generic keys (e.g., "GALICIA") carry a higher risk of false matches.

localStorage schema

Custom street entries are persisted in the browser’s localStorage under the key 'zonasCustom_v1'. The value is a JSON-stringified object with the same shape as zonasEstandar: uppercase string keys mapped to zone name strings. Key: 'zonasCustom_v1' Value format:
{
  "CALLE EJEMPLO": "Bilbao Centro",
  "NUEVA VIA": "Rekalde"
}
On startup, the app reads this key and merges its contents over the standard dictionary. Custom entries take priority over entries with the same key in zonasEstandar.
Clearing browser storage (e.g., via DevTools → Application → Local Storage) removes all custom entries. Export your custom dictionary as JSON before clearing storage if you want to keep your entries.

Unmatched streets export (.txt)

After processing, you can download a list of street values that had no zone match. The file is a plain text file with one street name per line.
Calle Sin Registro
Urbanización Nueva
Paseo Desconocido
This file is generated using Blob and URL.createObjectURL, then triggered as a browser download.

Custom dictionary export (JSON)

You can export your custom entries as a JSON file. The file contains the customStreets object formatted with two-space indentation:
JSON.stringify(customStreets, null, 2)
Example output:
{
  "CALLE EJEMPLO": "Bilbao Centro",
  "NUEVA VIA": "Rekalde"
}
You can use this file as a backup or to transfer custom entries to another browser or device.